<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>插槽</title>
  <script src="https://cdn.bootcss.com/vue/2.6.10/vue.js"></script>
</head>
<body>
<div id="app">
  <me-component>
    <h1>测试插槽</h1>
  </me-component>
</div>
<script >
  Vue.component('me-component', {
    template:
      `<div>
                    <p>你好</p>
                    <slot></slot>
                </div>`
  })
  var vm = new Vue({
    el:"#app"
  })
</script >
</body>
</html>
